package edu.rjh.reflection.reflection_3;

import lombok.Data;
import lombok.ToString;

@Data
@ToString
public class Student {
    private String name;
    private int age;

    public Student() {

    }

    public Student( int age, String name) {
        this.age = age;
        this.name = name;
    }

    public void study() {
        System.out.println("study");
    }
    private String eat(String food) throws NullPointerException{
        System.out.println("正在吃"+food);
        return "吃饱了";
    }

}
